import request from '@/utils/request'

// 查询图库列表
export function listInfo(query) {
  return request({
    url: '/gallery/info/list',
    method: 'get',
    params: query
  })
}

// 查询图库详细
export function getInfo(galleryInfoId) {
  return request({
    url: '/gallery/info/' + galleryInfoId,
    method: 'get'
  })
}

// 新增图库
export function addInfo(data) {
  return request({
    url: '/gallery/info',
    method: 'post',
    data: data
  })
}

// 修改图库
export function updateInfo(data) {
  return request({
    url: '/gallery/info',
    method: 'put',
    data: data
  })
}

// 删除图库
export function delInfo(galleryInfoId) {
  return request({
    url: '/gallery/info/' + galleryInfoId,
    method: 'delete'
  })
}

// 导出图库
export function exportInfo(query) {
  return request({
    url: '/gallery/info/export',
    method: 'get',
    params: query
  })
}

// 查询店铺列表
export function selectSupplierList(){
  return request({
    url: '/gallery/info/selectSupplierList',
    method: 'get',
  })
}

// 上传图片
export function uploadImage(data) {
  return request({
    url: '/gallery/info/uploadImage',
    method: 'post',
    data: data
  })
}
